package com.spa.infrastructure.mapper;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.spa.application.dto.PageResult;
import com.spa.application.dto.admin.MassagistAdminEditDTO;
import com.spa.application.dto.admin.MassagistOnofExportDTO;
import com.spa.application.dto.admin.MassagistOnoffDTO;
import com.spa.application.dto.admin.MassagistServiceTimeDTO;
import com.spa.application.query.admin.MassagitsServiceTimePageQuery;
import com.spa.application.query.admin.MassagitsonoffPageQuery;
import com.spa.domain.entity.Massagist;
import com.spa.domain.entity.MassagistOnoff;
import com.spa.infrastructure.repository.condition.MassagistOnoffCondition;
import com.spa.infrastructure.repository.po.MassagistOnoffPO;
import org.mapstruct.Mapper;
import org.mapstruct.MapperConfig;
import org.mapstruct.ReportingPolicy;
import org.mapstruct.factory.Mappers;

import java.util.List;

@Mapper
@MapperConfig(unmappedTargetPolicy = ReportingPolicy.WARN)
public interface MassagistOnoffMapperStruct {

    MassagistOnoffMapperStruct INSTANCE = Mappers.getMapper(MassagistOnoffMapperStruct.class);

    MassagistOnoffCondition query2condition(MassagitsServiceTimePageQuery query);

    MassagistOnoffCondition pageQuery2condition(MassagitsonoffPageQuery query);


    PageResult<MassagistServiceTimeDTO> po2Dto4page(Page<MassagistOnoffPO> query);

    PageResult<MassagistOnoffDTO> po2OnoffDto4page(Page<MassagistOnoffPO> query);


    MassagistAdminEditDTO entity2Dto4massagistAdmin(Massagist massagist);


    List<MassagistOnoff> po2Entity4List(List<MassagistOnoffPO> list);

    List<MassagistOnofExportDTO> entity2DTOExport(List<MassagistOnoff> massagistOnoff);
}
